<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="utf-8"%>
<%@ taglib prefix="s" uri="/struts-tags"%><%@ taglib uri="http://tiles.apache.org/tags-tiles" prefix="tiles"%>
<tiles:insertDefinition name="layout">
	<tiles:putAttribute name="head">
		<style type="text/css">
.selected {
	visibility: hidden;
}

#studentList .ui-selecting {
	background: #FECA40;
}

#studentList .ui-selected {
	background: #F39814;
	color: white;
}
</style>
		<script type="text/javascript" src="<s:url value='/client-resources/components/bootstrap-master-2.3.0/js/bootstrap-tooltip.js'/>"></script>
		<script type="text/javascript" src="<s:url value='/client-resources/components/bootstrap-master-2.3.0/js/bootstrap-popover.js'/>"></script>
		<script type="text/javascript">
			$(function() {
				var height = $("#lessonPanel").height();
				$("#lessonsTable").css("margin-top", height + "px");
			});
		</script>
	</tiles:putAttribute>
	<tiles:putAttribute name="mainBody">
		<form>
			<s:iterator value="selectedLessons" var="selectedLesson">
				<input name="selectedLesson" value="${selectedLesson}" />
			</s:iterator>
			<input name="selectedDay" value="${selectedDay}" /> <input name="selectedSign" />
		</form>
		<div class="span4 pull-right">
			<div style="position: fixed;">
				<fieldset>
					<legend>学员查找</legend>
					<select class="input-small" name="type">
						<option>输入查找</option>
						<option>指纹登记</option>
					</select> <input type="text" class="input-medium" autocomplete="off" id="searchText" name="searchText" />
					<button type="submit" class="btn btn-primary">订课</button>
				</fieldset>
				<table class="table">
					<thead>
						<tr>
							<th>姓名</th>
							<th>学号</th>
							<th>注册课程</th>
						</tr>
					</thead>
					<tbody id="studentList">
						<s:iterator value="students" var="student">
							<tr>
								<td>${student.name}</td>
								<td>${student.stuId}</td>
								<td>课程</td>
							</tr>
						</s:iterator>
					</tbody>
				</table>
				<div id="logs"></div>
			</div>
		</div>
		<div style="position: fixed; width: 50%" id="lessonPanel">
			<div class="clearfix well well-small">
				<div class="pull-left">
					<div id="datepicker"></div>
				</div>
				<fieldset style="margin-left: 280px">
					<legend style="margin-bottom: 0px">
						选择课程<small>双击课程进行选择</small>
						<a class="btn btn-small btn-danger" id="btnClear">清空</a>
						<span class="form-inline"> <label class="checkbox">
								<input type="checkbox" name="single" checked="checked" id="cbSingle">单选模式
							</label>
						</span>
					</legend>
					<dl id="lessons">
					</dl>
				</fieldset>
			</div>
		</div>
		<div style="margin-right: 37%" id="lessonsTable">
			<table class="table table-hover" style="cursor: pointer;">
				<thead>
					<tr>
						<th>Time</th>
						<th>Lesson</th>
						<th>Teacher</th>
						<th>Classroom</th>
						<th>Listener</th>
					</tr>
				</thead>
				<tbody id="selectable">
					<s:iterator value="lessons" var="lesson">
						<tr>
							<td>${lesson}</td>
							<td></td>
							<td></td>
						</tr>
					</s:iterator>
				</tbody>
			</table>
		</div>
	</tiles:putAttribute>
</tiles:insertDefinition>